package com.example.crt_dispatching_center.controller;

import com.example.crt_dispatching_center.entity.Fare;
import com.example.crt_dispatching_center.service.FareService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;
import java.util.Map;

@RestController
@RequestMapping("/fare")
public class FareController {
    @Autowired
    private FareService FareService;

    @GetMapping("/past7days")
    public Map<String, List<?>> getFare(){
        return FareService.getFare();
    }
}
